import Vue from 'vue'
import Vuex from 'vuex'
import Config from './config.js'
import Init from './app'
import qs from 'qs'
import router from './routers/router'
import AtElement from 'atelement'
import 'atelement/lib/minhang.css'
import 'echarts/map/js/world.js'
import './fonts/saasIcon/iconStyle.css' // 字体图标

// 公共部分(登陆、单点登录、导航)
import system from './models/system'
import register from './models/register'

import blankpage from './models/blankpage'

// 系统监测--监测日志、事件管理、安全分析、风险事项、风险预警)
import riskevent from './models/riskevent'
import riskwarning from './models/riskwarning'
import safeEvents from './models/safeEvents/safeEvents'
import eventManagement from './models/eventManagement'
// 统计管理--安全状态画像、报表报告)
import safePortraiat from './models/safePortraiat'
import report from './models/report'
import safetyForm from './models/safetyForm'// 报表报告-报表
// 业务管理--基础信息管理(机构管理、信息系统管理、系统节点管理)、任务管理、权限管理(角色管理、用户管理、用户组管理)、操作日志
import taskManagement from './models/taskManagement'
import taskManagementLog from './models/taskManagementLog/taskManagementLog'
import mechanism from './models/mechanism' // 基础信息管理-机构管理
import informationSystem from './models/informationSystem' // 基础信息管理-信息系统
import systemNode from './models/systemNode' // 基础信息管理-系统节点

import users from './models/users'// 权限管理-用户管理
import group from './models/group'// 权限管理-用户组管理
import role from './models/role'// 权限管理-角色管理
import operatelog from './models/operatelog' // 操作日志

// 运行管理--运行监控
import operationMonitor from './models/operationMonitor' // 运行监控
import analyze from './models/analyze/analyze' // 安全分析

Vue.prototype.$qs = qs
document.title = Config.title
Vue.use(Vuex)
Vue.use(AtElement)
let store = new Vuex.Store({
  modules: {
    system: system,
    register: register,
    blankpage: blankpage,
    mechanism: mechanism,
    informationSystem: informationSystem,
    systemNode: systemNode,
    users: users,
    group: group,
    role: role,
    operatelog: operatelog,
    safeEvents: safeEvents,
    operationMonitor: operationMonitor,
    safePortraiat: safePortraiat,
    report: report,
    riskevent: riskevent,
    riskwarning: riskwarning,
    safetyForm: safetyForm,
    eventManagement: eventManagement,
    analyze: analyze,
    taskManagement: taskManagement,
    taskManagementLog: taskManagementLog
  }
})
new Vue({
  router,
  store,
  render: h => h(Init)
}).$mount('#init')
